package cn.ld.fj.service.statistic;

import cn.ld.fj.dao.statistic.StatisticDAO;
import cn.ld.fj.pojo.PeopleStatisticPojo;
import cn.ld.fj.pojo.SaleStatisticPojo;
import cn.ld.fj.pojo.Top5FoodStatisticPojo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;
import java.util.Map;

/**
 * Created by lixiangjun on 2017/8/7.
 */
@Component
@Transactional
public class StatisticManager {
    @Autowired
    private StatisticDAO statisticDAO;

    public List<SaleStatisticPojo> saleStatistics(Map<String, Object> condtion) {
        return statisticDAO.saleStatistics(condtion);
    }

    public List<Top5FoodStatisticPojo> top5FoodStatistic(Map<String, Object> condtion) {
        return statisticDAO.top5FoodStatistic(condtion);
    }

    public List<PeopleStatisticPojo> peopleStatistic(Map<String, Object> condtion) {
        return statisticDAO.peopleStatistic(condtion);
    }
}
